<body>
<div class="divmain">
<table width="100%" id="fmfrmreporttime_tblinfo" class="tblInfo">
<tr>
<td valign="top" class="width25">
<div class="divLeft">  
<table class="info" id="fmfrmreporttime_tblcondition">
<tr >
<td  class="width100 clssearch" id="fmfrmreporttime_tdcondsearch">

<table class="width100">
 <tr><td>Thời gian</td>
<td><input type="text" value="" class="datereport txtRequired" onblur="formatddmmyyyy(this)" maxlength="10"  id="fmfrmreporttime_fromdate"/><a href="javascript:fmfrmreporttime_cal1.popup();">
<img src="adagps.com/images/cal/cal2.png" id="fmfrmreporttime_imgCal1"   class="datepicker dpkstart" ></a>
-
<input type="text" class="datereport txtRequired" onblur="formatddmmyyyy(this)" maxlength="10"  value=""  id="fmfrmreporttime_todate" /><a href="javascript:fmfrmreporttime_cal2.popup();">
<img src="adagps.com/images/cal/cal2.png" id="fmfrmreporttime_imgCal2"    class="datepicker dpkend" ></a>  </td></tr>
<tr><td rowspan="3">Loại báo cáo</td><td><input type="radio" checked="checked" name="fmfrmreporttime_reporttype" id="fmfrmreporttime_reporttype_1" value="1">
Thu nhập theo ngày</input> </td></tr>
<tr><td colspan="2"><input type="radio"  name="fmfrmreporttime_reporttype" id="fmfrmreporttime_reporttype_2" value="2">Thu nhập theo tuần</input></td></tr>
<tr><td colspan="2"><input type="radio"  name="fmfrmreporttime_reporttype" id="fmfrmreporttime_reporttype_3" value="3">Thu nhập theo tháng</input></td></tr> 
</table>
       <div class="divactionbuton">

        <button id="fmfrmreporttime_create" class="bntreport" onclick="fmfrmreporttime_createReport();" type="button"> Xem </button>
        </div>
</td>
</tr>
<tr>
<td>

<!--<button id="fmfrmreporttime_create" class="btnreport" onclick="fmfrmreporttime_createReport();" type="button"> Xem </button>-->
</td>
</tr>
</table>   
</div>
</td>
<td class="clsmiddle"></td>

<td width="80%" height="400" valign="top">
<div class="divGrid" id="fmfrmreporttime_divGrid">

</div></td>
<td class="clsend"></td>
</tr>
</table>
</div>

</body>
<script language="javascript">
changeWaiting(0); 
 $(document).ready(function () {
     initDivleft();
     initForm('fmfrmreporttime_tblinfo');  
     
 });
var fmfrmreporttime_cal1 = CreateCalObject('fmfrmreporttime_fromdate', 'fmfrmreporttime_imgCal1');
var fmfrmreporttime_cal2 = CreateCalObject('fmfrmreporttime_todate', 'fmfrmreporttime_imgCal2');

function fmfrmreporttime_createReport(){ 
    if(!checkDate('fmfrmreporttime_fromdate','fmfrmreporttime_todate',30)){
        return false;
    }
     fromdate = ConvertoDateEN($('#fmfrmreporttime_fromdate').val());
     todate = ConvertoDateEN($('#fmfrmreporttime_todate').val());
     reporttype = $('INPUT[NAME=fmfrmreporttime_reporttype]:checked').val();
     changeWaiting(0);
     xajax_fmfrmreporttime_load(fromdate,todate,reporttype);  
}

$('#fmfrmreporttime_fromdate').val(GetCurrentDateTime(0,1,false,0)) ;
$('#fmfrmreporttime_todate').val(GetCurrentDateTime(0,0,false,0)) ;
  

changeWaiting(0);
fmfrmreporttime_createReport();

 </script>

